package com.xuelang.pipeline.app.pipeline;


import com.xuelang.pipeline.client.pipeline.dto.MeasDTO;
import feign.Param;
import feign.RequestLine;
import org.springframework.cloud.openfeign.FeignClient;

/**
 * @author liuyuan.ly
 * @since 2024/7/22 15:21
 */

@FeignClient(name = "sonar-service")
public interface SonarqubeClient {

    /**
     * 查询sonarqube代码扫描结果
     *
     * @param applicationCode
     * @param metricKeys
     * @return
     */
    @RequestLine("GET /api/measures/component?component={component}&metricKeys={metricKeys}")
    MeasDTO getSonarDetail(@Param("component") String applicationCode,
                           @Param("metricKeys") String metricKeys);
}
